<style>
    .layui-form-label {
        width: 80px !important;
    }

    .layui-input-block {
        margin-left: 130px !important;
    }

    .layui-iconpicker {
        max-width: 100%;
    }
</style>
<div class="layuimini-container">
    <form id="app-form" class="layui-form layuimini-form" v-cloak="">
        <input type="hidden" name="config_tab_id" value="{$tab_id}">
        <div class="layui-form-item  layui-row layui-col-xs12">
            <label class="layui-form-label required">类型</label>
            <div class="layui-input-block">
                <select name="type" lay-filter="input_type">
                    <option v-for="(item,key) in inputTypeList" :value="item.value" :key="key">{{ item.label}}</option>
                </select>
            </div>
        </div>

        <div class="layui-form-item" v-if="type == 'date'">
            <label class="layui-form-label">日期类型</label>
            <div class="layui-input-block">
                <input type="radio" name="date_type" value="date" title="日期" checked>
                <input type="radio" name="date_type" value="time" title="时间">
                <input type="radio" name="date_type" value="datetime" title="日期时间">
            </div>
        </div>

        <div class="layui-form-item" v-if="type == 'frame'">
            <label class="layui-form-label">上传类型</label>
            <div class="layui-input-block">
                <input type="radio" name="upload_type" value="1" title="单图" checked>
                <input type="radio" name="upload_type" value="2" title="多图">
            </div>
        </div>

        <div class="layui-form-item" v-if="type == 'upload'">
            <label class="layui-form-label">文件类型</label>
            <div class="layui-input-block">
                <input type="radio" name="upload_type" value="1" title="单图" checked>
                <input type="radio" name="upload_type" value="3" title="文件">
            </div>
        </div>

        <div class="layui-form-item layui-form-text" v-if="['radio','checkbox'].includes(type)">
            <label class="layui-form-label">配置参数</label>
            <div class="layui-input-block">
                <textarea name="parameter" lay-verify="required" placeholder="参数方式例如:&#10;1=>男&#10;2=>女&#10;3=>保密" class="layui-textarea"></textarea>
            </div>
        </div>

        <div class="layui-form-item">
            <label class="layui-form-label required">配置名称</label>
            <div class="layui-input-block">
                <input type="text" name="info" class="layui-input"
                       lay-verify="required" placeholder="请输入配置名称" value="">
            </div>
        </div>

        <div class="layui-form-item">
            <label class="layui-form-label required">配置英文名称</label>
            <div class="layui-input-block">
                <input type="text" name="menu_name" class="layui-input"
                       lay-verify="required" placeholder="请输入配置英文名称" value="">
            </div>
        </div>

        <div class="layui-form-item">
            <label class="layui-form-label">配置简介</label>
            <div class="layui-input-block">
                <input type="text" name="desc" class="layui-input" placeholder="请输入配置简介" value="">
            </div>
        </div>

        <div class="layui-form-item">
            <label class="layui-form-label">默认值</label>
            <div class="layui-input-block">
                <input type="text" name="value" class="layui-input" placeholder="请输入默认值" value="">
            </div>
        </div>

        <div class="layui-form-item" v-if="type == 'text'">
            <label class="layui-form-label">是否必填</label>
            <div class="layui-input-block">
                <input type="radio" name="required" value="1" title="是">
                <input type="radio" name="required" value="0" title="否" checked>
            </div>
        </div>

        <div class="layui-form-item">
            <label class="layui-form-label">排序</label>
            <div class="layui-input-block">
                <input type="number" name="sort" lay-reqtext="分类排序不能为空" placeholder="请输入分类排序" value="0" min="0" class="layui-input">
            </div>
        </div>

        <div class="layui-form-item">
            <label class="layui-form-label">状态</label>
            <div class="layui-input-block">
                <input type="radio" name="status" value="1" title="显示" checked>
                <input type="radio" name="status" value="0" title="隐藏">
            </div>
        </div>

        <div class="hr-line"></div>
        <div class="layui-form-item text-center">
            <button type="submit" class="layui-btn layui-btn-normal layui-btn-sm" lay-submit="system.config.systemConfig/save">
                确认
            </button>
            <button type="reset" class="layui-btn layui-btn-primary layui-btn-sm">重置</button>
        </div>

    </form>
</div>

<script>
    let row = {};
</script>